package cn.netjava.filter;

import javax.servlet.Filter;
/**
 * filter the ecode
 * @author Administrator
 *
 */
public class EcodingFilter implements Filter {

	 public  void init(javax.servlet.FilterConfig arg0) throws javax.servlet.ServletException{
		 
	 }
	  	 
	  public  void doFilter(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain arg2) throws java.io.IOException, javax.servlet.ServletException{
		  request.setCharacterEncoding("utf-8");
		  response.setCharacterEncoding("utf-8");
		  arg2.doFilter(request, response);
	  }
	  
	  public  void destroy(){
		  
	  }

}
